1. Field of the Invention
The present invention relates generally to the field of graphics processing and more specifically to a system and method for determining a bus address on an add-in card.
2. Description of the Related Art
A typical computing system includes a central processing unit (CPU) and a graphics processing unit (GPU). Some GPUs are capable of very high performance using a relatively large number of small, parallel execution threads on dedicated programmable hardware processing units. The specialized design of such GPUs usually allows these GPUs to perform certain tasks, such as rendering three-dimensional (3D) scenes, much faster than a CPU. However, the specialized design of these GPUs also limits the types of tasks that the GPU can perform. The CPU is typically a more general-purpose processing unit and therefore can perform most tasks. Consequently, the CPU usually executes the overall structure of a software application and configures the GPU to perform specific tasks in a graphics pipeline.
In a hybrid computing system, there may be a plurality of GPUs working together to perform certain tasks. An integrated GPU (iGPU) generally provides lower-power graphics processing, and one or more discrete GPUs (dGPU) provides higher-performance graphics processing. Most commonly, a dGPU is located on an add-in card that is connected to the computing system via a Peripheral Component Interconnect Express (PCI Express or PCIe) expansion bus and slot.
One goal of a hybrid computing system is to save power by turning OFF the dGPU and switching processing to only the lower-power iGPU when the additional processing capabilities of the dGPU are not needed. A hybrid microcontroller (hEC) is located on the add-in card with the dGPU and controls power to the dGPU. Most commonly, the hEC is addressable via a system management bus (SMBus) interface and, therefore, requires a unique SMbus address to be accessed by the System Basic Input/Output System (SBIOS) and graphics driver. Any number of similar add-in cards, each with one or more hECs, as well as other SMbus devices (e.g., a dual in-line memory module or a network adapter) may be located in the system. Each of these add-in cards and other SMbus devices requires a unique SMbus address too. Additionally, further add-in cards and other devices can be added, removed, or replaced in the system. Since the system configuration can change, using a fixed address scheme is not a viable solution for assigning SMbus addresses to the add-in cards and other SMbus devices.
As a general matter, assigning SMbus addresses to add-in cards has proven to be challenging. The primary problem is that the SBIOS is generally not pre-programmed to know the SMbus addresses of each of the slots on the PCIe bus or which slot corresponds to the SMbus address of the particular hEC that controls the GPU on a particular add-in card. In addition, the graphics driver cannot determine the SMbus address because the graphics driver cannot communicate with a device that is OFF, nor can the graphics driver access the registers of an hEC device.
In certain prior art approaches, an Address Resolution Protocol (ARP) has been used to dynamically resolve SMbus addresses. ARP is a well-known protocol that requires all devices to start in an OFF state at a default listening address. Then, a broadcast is transmitted to all devices on a bus, and the first device that responds “wins” that address. This round-robin protocol is then repeated until each device receives a unique address. There are several limitations of ARP that cause the protocol to function more inefficiently than intended. First, not all hECs are compatible with ARP. For example, sometimes an hEC cannot respond to two addresses simultaneously, which causes the hEC to not respond at the default listening address and carry out the ARP protocol. This incompatibility precludes an SMbus address from being assigned to the hEC. Second, almost no original equipment manufacturer (OEM) implements ARP in their motherboards. ARP is simply too complex for many OEMs to implement, and the protocol is almost universally disfavored.
As the foregoing shows, what is needed in the art is a simpler technique for assigning SMbus addresses to hECs included on graphics add-in cards that is compatible with different types of hECs and different OEM motherboard configurations.